package com.polly.esphwevent.common.exceptions;

/**
 * @author liqin@nd.com.cn
 * @version V1.0
 * @title: AuthExceptionEnum
 * @description: TODO(用一句话描述该文件做什么)
 * @date: 2019/2/21 21:08
 */

public enum AuthExceptionEnum {

    TOKEN_EMPTY(8001, "登录令牌为空，请检查是否已经登录"),
    TOKEN_ERROR(8002, "token错误"),
    TOKEN_EXPIRED(8003,"token过期"),
    TOKEN_INVALID(8004,"token无效"),
    NO_PERMISSION(8009, "没有访问该资源的权限");

    AuthExceptionEnum(int code, String message) {
        this.code = code;
        this.message = message;
    }

    private int code;

    private String message;

    public Integer getCode() {
        return code;
    }

    public String getMessage() {
        return message;
    }

    public void setCode(int code) {
        this.code = code;
    }

    public void setMessage(String message) {
        this.message = message;
    }

}
